import request from '@/config/axios'

export type EquipmentVO = {
  id: number
  status: number
  equipmentName: string
  equipmentModel: string
  testDuration: string
  testPurpose: string
  applicant: string
  contact: string
  processInstanceId: string
  createTime: string
}

// 创建参试设备申请
export const createEquipment = async (data: EquipmentVO) => {
  return await request.post({ url: '/bpm/oa/equipment/create', data: data })
}

// 获得参试设备申请
export const getEquipment = async (id: number) => {
  return await request.get({ url: '/bpm/oa/equipment/get?id=' + id })
}

// 获得参试设备申请分页
export const getEquipmentPage = async (params: PageParam) => {
  return await request.get({ url: '/bpm/oa/equipment/page', params })
}